<template>
	<view class="apply-status-container">
	  <!-- 审核中状态 -->
	  <view v-if="status == 0" class="status-card">
		<image class="status-icon" src="/static/icon/audit.png"></image>
		<view class="status-title">审核中</view>
		<view class="status-desc">您的申请正在审核中，请耐心等待</view>
		<button class="back-btn" @click="goBack">返回</button>
	  </view>
  
	  <!-- 审核失败状态 -->
	  <view v-if="status == 2" class="status-card">
		<image class="status-icon" src="/static/icon/reject.png"></image>
		<view class="status-title">审核失败</view>
		<view class="status-desc">{{ rejectReason || '您的申请未通过审核' }}</view>
		<button class="back-btn" @click="goBack">返回</button>
		<button class="reapply-btn" @click="reapply">重新申请</button>
	  </view>
	</view>
  </template>
  
  <script>
  export default {
	data() {
	  return {
		status: 0, // 0=审核中，2=审核失败
		rejectReason: '' // 审核失败原因
	  }
	},
	onLoad(options) {
	  // 获取URL参数
	  this.status = options.status || 0
	  this.rejectReason = options.reason || ''
	},
	methods: {
	  goBack() {
		uni.navigateBack({
		  delta: 1
		})
	  },
	  reapply() {
		// 跳转到重新申请页面
		uni.navigateTo({
		  url: '/pagesA/my/tools/apply_hn_rule'
		})
	  }
	}
  }
  </script>
  
  <style lang="scss">
  .apply-status-container {
	height: 90vh;
	background-color: #FFF5F7; // 粉色背景
	display: flex;
	justify-content: center;
	align-items: center;
	padding: 20px;
	
	.status-card {
	  background-color: #fff;
	  border-radius: 16px;
	  padding: 40px 30px;
	  width: 100%;
	  max-width: 400px;
	  box-shadow: 0 4px 15px rgba(241, 67, 153, 0.1);
	  text-align: center;
	  
	  .status-icon {
		width: 80px;
		height: 80px;
		margin-bottom: 20px;
	  }
	  
	  .status-title {
		font-size: 24px;
		font-weight: bold;
		color: #F14399; // 主粉色
		margin-bottom: 10px;
	  }
	  
	  .status-desc {
		font-size: 16px;
		color: #666;
		margin-bottom: 30px;
		line-height: 1.5;
	  }
	  
	  .back-btn {
		background-color: #F8BBD0; // 浅粉色
		color: #fff;
		border-radius: 25px;
		height: 50px;
		line-height: 50px;
		font-size: 16px;
		margin-bottom: 15px;
	  }
	  
	  .reapply-btn {
		background-color: #F14399; // 主粉色
		color: #fff;
		border-radius: 25px;
		height: 50px;
		line-height: 50px;
		font-size: 16px;
	  }
	}
  }
  </style>